Pull the Oracle Java Base Image

  1. Pull the Oracle Java image from container-registry.oracle.com Version: 17 (Recommended Java Version: Java 17)

  2. Before pulling this image from the Container Registry, make sure that the Docker client has logged in successfully using the docker login command:

    # docker login container-registry.oracle.com

    Username

    Password

    Login successful.

  3. Use your Oracle SSO username and password to log in to the Oracle Registry.

  4. Pull Oracle Java base image version 17

    $ docker pull container-registry.oracle.com/java/jdk:17

    Docker Service Layer Java Image

    Important: The resulting images will NOT have a TomEE pre-configured. You must extend the image with your own Dockerfile, and create your TomEE environment.

  5. In the Dockerfile extend the Oracle Java image with the 'FROM container-registry.oracle.com/java/jdk:17' directive.

    Note: Place the "tomee.tar.gz" file in the Dockerfile location.

TomEE Directory Structure

A few important directories in the TomEE server are as follows:

  • /bin: This directory contains the startup and shutdown scripts for both Windows and Linux.

  • /conf: This directory contains the main configuration files for TomEE. The two most important are the server.xml and the global tomee.xml.

  • /lib: This directory contains Java Archive files that TomEE is dependent upon.

  • /logs: This directory contains TomEE log files.

  • /webapps: All web applications are deployed in this directory; it contains the WAR file.

  • /work: This is the directory in which TomEE will place all servlets that are generated.